<!DOCTYPE html>
<html lang="en">
<head>
    <meta charset="UTF-8">
    <title>我的评价</title>
    <meta name="viewport" content="width=100%; initial-scale=1.0; maximum-scale=1.0; user-scalable=0;" />

    <link rel="stylesheet" href="http://at.alicdn.com/t/font_604068_mskca9dc7wcm1jor.css" />

    <script src="/static/js/vue.min.js"></script>
    <script src="https://cdn.bootcss.com/jquery/1.11.0/jquery.min.js"></script>
    <script src="https://cdn.bootcss.com/jquery-weui/1.2.0/js/jquery-weui.min.js"></script>
    <script src="/static/js/vue.js"></script>

    <link rel="stylesheet" href="/static/jquery-weui/css/weui.min.css">
    <link rel="stylesheet" href="/static/jquery-weui/css/jquery-weui.css">
    <link rel="stylesheet" href="/static/jquery-weui/css/demos.css">

    <script src="/static/jquery-weui/js/jquery-2.1.4.js"></script>
    <script src="/static/jquery-weui/js/fastclick.js"></script>

    <script src="/static/jquery-weui/js/jquery-weui.js"></script>
    <link rel="stylesheet" href="/static/mui/css/mui.css" />

    <script src="/static/js/jquery.min.js"></script>
    <script src="/static/js/jquery.raty.min.js"></script>

    <style>


        button{
            background-color: #ffffff;
            color: black;
            border: 1px solid  #fe8200;
            width: 60px;
            height: 30px;
            border-radius: 5px;
        }


        .headTitle {
            position: fixed;
            border: 1px solid #f4f4f4;
            border-top: none;
            border-left: none;
            border-right: none;
            background: #fff;
            width: 100%;
            height: 44px;
            line-height: 44px;
        }
        .head {
            position: absolute;
            width: 100%;
            max-width: 640px;
            right: 0;
            margin: 0 auto;
            height:44px;
            background: rgb(255, 255, 255);
            top: 0;
            left: 0;
            z-index: 3;
        }
        .head .title1 {
            text-align: center;
            font-size: 17px;
            margin: 0 8%;
            font-style: normal;
            font-weight: normal;
            white-space: nowrap;
            overflow: hidden;
            text-overflow: ellipsis;
            height: 100%;


        }
        .head a img {
            float: left;
            display: block;
            width: 100%;
            width: 10px;
            height: 16px;
            margin-left: 5%;
            margin-top: 14px;
        }

        ::-webkit-input-placeholder{
            font-size:13px;
        }


    </style>
</head>
<body style="background-color: white">
<header class="head headTitle"   style="position: fixed;top: 0px;">
    <a class="back"   href="{:url('/home/logintest/my_decoration')}" >
        <img src="/static/images/back_gray.png">
    </a>
    <h6 class="title1"   style="line-height: 44px">我的评价</h6>

</header>

<div style="margin-top: 44px;
    border-top: 4px solid #efeff4;">

    <form id="appraise" class="appraise" >
        <!--评星开始-->
        <div style="background-color: white;height: 45px;">
            <div style="float:left;padding: 12px;">满意程度：</div>
            <div id="star" style="float:left;padding: 10px"></div>
            <div id="result" style="padding: 12px; color: gray;"></div>
        </div>
        <!--评星结束-->

        <!--评价内容开始-->
        <div id="content" style="border-top: 2px solid #efeff4;">
            <textarea id="editor" name="editor"  style="background-color: white;height: 250px;border: 0px;" placeholder="请输入内容">

            </textarea>
        </div>
        <!--评价内容结束-->

        <div style="margin-top: -20px; border-top: 4px solid #efeff4;">
            <button id="sub" name="sub" data_id="" style="left: 40%;margin-top: 5px;" type="button" onclick="sub11()">提交</button>
        </div>
    </form>




</div>

<script>
    $('#star').raty({
        path:"/static/images/img",
        hints:['1','2','3','4','5'],
        starOff: 'star-off-big.png',
        starOn: 'star-on-big.png',
        size:30,
        target:'#result',
        targetKeep:true
    });


    function sub11() {
        var text = $('#result').text();
        console.log(text+'bbbb');

        var editor = $('#editor').val();
        console.log(editor+'aaaa');



        $.ajax({
            type:"post",
            url:"my_decoration_detail",
            dataType:'JSON',
            data:{content:editor,text:text,id:"{$Request.param.id}"},
            success: function (data){
                console.log(data);
                alert('aaaaaaaaaa');
                //window.location.href="my_decoration.html"
            }
        })

    }


</script>

</body>
</html>